package com.sunny.shop.repository;

import com.sunny.shop.model.Sign;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import javax.xml.crypto.Data;
import java.util.Date;

public interface SignRepository extends JpaRepository<Sign,Long> {
    @Query("select s from Sign as s where s.uid = :uid and s.signTime = :sign_time")
    Sign findToday(Long uid, String sign_time);

    Long countAllByUid(Long uid);

}
